package com.hq.fxh.No5_User.User.Adapter;

import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.hq.fxh.R;

/**
 * /**
 *
 * @author 薛
 * @ClassName
 * @Description :
 * @Created 2017/9/18
 * @Email xlwenhao1858@sina.com
 */


public class Ladapter_MyZan extends BaseAdapter {
    @Override
    public int getCount() {
        return 10;
    }

    @Override
    public Object getItem(int i) {
        return null;
    }

    @Override
    public long getItemId(int i) {
        return 0;
    }

    @Override
    public View getView(int i, View convertView, ViewGroup parent) {
        View view = convertView;
        ViewHolder viewHolder = null;
        if (view == null || !(view.getTag() instanceof ViewHolder)) {
            view = LayoutInflater.from(parent.getContext()).inflate(R.layout.item_comment, null);
            viewHolder = new ViewHolder(view);
            view.setTag(viewHolder);
        } else {
            viewHolder = (ViewHolder) view.getTag();
        }

        return view;
    }

    static class ViewHolder {
        protected ImageView imageDetailIcon;
        protected TextView tvDetailName;
        protected ImageView imageZan;
        protected TextView tvZan;
        protected LinearLayout layoutZan;
        protected TextView tvDetailHuiFu;
        protected TextView tvDetailCommentContent;
        protected TextView tvDetailCommenTime;
        protected ImageView imageFather1Pic;
        protected TextView tvFather1Content;
        protected LinearLayout layoutCommentFather1;
        protected TextView tvFather2Name;
        protected TextView tvFather2Content;
        protected LinearLayout layoutCommentFather2;

        ViewHolder(View rootView) {
            initView(rootView);
        }

        private void initView(View rootView) {
            imageDetailIcon = (ImageView) rootView.findViewById(R.id.image_detail_Icon);
            tvDetailName = (TextView) rootView.findViewById(R.id.tv_detail_Name);
            imageZan = (ImageView) rootView.findViewById(R.id.image_Zan);
            tvZan = (TextView) rootView.findViewById(R.id.tv_Zan);
            layoutZan = (LinearLayout) rootView.findViewById(R.id.layout_Zan);
            tvDetailHuiFu = (TextView) rootView.findViewById(R.id.tv_detail_HuiFu);
            tvDetailCommentContent = (TextView) rootView.findViewById(R.id.tv_detail_CommentContent);
            tvDetailCommenTime = (TextView) rootView.findViewById(R.id.tv_detail_CommenTime);
            imageFather1Pic = (ImageView) rootView.findViewById(R.id.image_father1_pic);
            tvFather1Content = (TextView) rootView.findViewById(R.id.tv_father1_content);
            layoutCommentFather1 = (LinearLayout) rootView.findViewById(R.id.layout_CommentFather_1);
            tvFather2Name = (TextView) rootView.findViewById(R.id.tv_father2_name);
            tvFather2Content = (TextView) rootView.findViewById(R.id.tv_father2_content);
            layoutCommentFather2 = (LinearLayout) rootView.findViewById(R.id.layout_CommentFather_2);
        }
    }
}
